<template>
	<view class="achievement-item">
		<!-- 头部卡片 -->
		<view class="head">
			<image class="head-img" src="https://placehold.jp/999999/ff4400/224x160.png?text=EXAMPLE" mode="aspectFit" />
			<view class="head-txt">
				<view class="tit">我是张天师</view>
				<view class="head-tag">
					<view class="head-tag_sex">男</view>
					<view class="head-tag_year">工作经验15年</view>
				</view>
			</view>
			<view class="detail-btn" @click="toDetail">
				<text class="txt">详情></text>
			</view>
		</view>
		
		<!-- 信息 -->
		<view class="info">
			<view class="info-item">
				<text class="tit">籍贯：</text>
				<text class="value">湖南</text>
			</view>
			<view class="info-item">
				<text class="tit">联系方式：</text>
				<text class="value">15636536598</text>
			</view>
			<view class="info-item">
				<text class="tit">使用语言：</text>
				<text class="value">普通话</text>
			</view>
			<view class="info-item">
				<text class="tit">注册日期：</text>
				<text class="value">2024/5/26</text>
			</view>
			<view class="info-item info-row">
				<text class="tit">简要描述：</text>
				<text class="value into-desc">厂出率都号积头军为现育火太料当成产明易点说上法连广好南马它我。</text>
			</view>
		</view>
		
		<!-- 标签 -->
		<view class="tag-wrap">
			<view class="tag-item">热心</view>
			<view class="tag-item">努力向上</view>
			<view class="tag-item">技术NB</view>
			<view class="tag-item">勤奋</view>
		</view>
	</view>
</template>

<script>
	export default {
		props: {
			item: {
				type: Object,
				default() {
					return null;
				}
			}
		},
		data() {
			return {
				
			}
		},
		methods: {
			
		}
	}
</script>

<style lang="scss" scoped>
.achievement-item {
	width: 100%;
	padding: 25rpx 22rpx;
	box-sizing: border-box;
	margin-bottom: 24rpx;
	border-radius: 12rpx;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	position: relative;
	background-color: #ffffff;
}
	// 头部卡片 
	.head {
		box-sizing: border-box;
		display: flex;

		.head-img {
			flex-shrink: 0;
			width: 224rpx;
			height: 160rpx;
			margin-right: 20rpx;
		}

		.head-txt {
			flex-grow: 1;
			.tit {
				font-size: 40rpx;
				font-weight: 700;
				line-height: 48rpx;
				margin-bottom: 20rpx;
				color: #111111;
			}

			.head-tag {
				display: flex;
				.head-tag_sex {
					display: flex;
					justify-content: center;
					align-items: center;
					flex-shrink: 0;
					box-sizing: border-box;
					width: 77rpx;
					height: 53rpx;
					padding: 8rpx 16rpx;
					border-radius: 6rpx;
					white-space: normal;
					margin-right: 13rpx;
					white-space: nowrap;
					font-size: 26rpx;
					font-weight: 500;
					background: #41D2FF;
					color: #ffffff;
				}

				.head-tag_year {
					display: flex;
					box-sizing: border-box;
					height: 53rpx;
					padding: 8rpx 16rpx;
					justify-content: center;
					align-items: center;
					flex-shrink: 0;
					border-radius: 6rpx;
					background: linear-gradient(90deg, #E38024 0%, #EB4242 100%);
					color: #ffffff;
					font-size: 30rpx;
					font-weight: 500;
				}
			}
		}

		.detail-btn {
			position: absolute;
			right: 0;
			top: 28rpx;
			width: 128rpx;
			height: 56rpx;
			display: flex;
			box-sizing: border-box;
			padding: 4rpx 24rpx;
			align-items: center;
			gap: 8rpx;
			border-radius: 46rpx 0 0 46rpx;
			background: linear-gradient(270deg, #1D6BFF 0%, #369BFF 100%);

			.txt {
				color: #ffffff;
				font-size: 30rpx;
				font-style: normal;
				font-weight: 500;
				line-height: 48rpx;
				flex-shrink: 0;
				flex-grow: 1;
			}

			.icon {
				width: 12rpx;
				height: 38rpx;
			}
		}
	}

	// 信息
	.info {
		margin-top: 12rpx;
		display: flex;
		flex-wrap: wrap;
		box-sizing: border-box;

		.info-item {
			display: flex;
			width: 50%;
			margin-bottom: 20rpx;

			&.info-row {
				width: 100%;
			}

			.tit {
				font-size: 28rpx;
				white-space: nowrap;
				margin-right: 5rpx;
				color: #666666;
			}

			.value {
				font-size: 28rpx;
				font-weight: bold;
				color: #111111;
			}

			.into-desc {
				flex: 1;
				white-space: nowrap;
				overflow: hidden;
				text-overflow: ellipsis;
			}
		}
	}

	// 标签 
	.tag-wrap {
		display: flex;
		overflow-y: hidden;
		overflow-x: auto;
		flex-wrap: nowrap;

		.tag-item {
			flex-shrink: 0;
			display: flex;
			padding: 8rpx 20rpx;
			align-items: center;
			justify-content: center;
			border-radius: 41rpx;
			font-size: 30rpx;
			margin-right: 12rpx;
			margin-bottom: 10rpx;
			background: rgba(#287EFF, 0.14);
			color: #287EFF;
		}
	}
</style>
